The below example will prompt you for a time in which to wait. Once entered, the routine will call the timer.device and wait for the specified time. It will then tell you when all is well.
It is a simple example, taken from the RKM Devices Third Edition, and shows how you should wait for a message from the OS via message ports. Any device operates very similar, including the serial.device, which was the original point raised IIRC.
Take a look.For anybody who's interested, here's a proper example of how to wait for Ctrl_C. Compile this into an executable, and then run it from the shell. You can then either break it by hitting ^C or by issuing a 'Break' with the AmigaDOS command Break or with ARTM or similar. It doesn't matter how you do it, all that matters is that it sleeps while it's waiting and not running a loop!
Take a look.After a time searching for a good way to run programs from Blitz i find a way that could help many people i think. I did see there are many people having troubles finding there way in a good solution for running external programs from inside your own program. This will do the job in all cases. Except i think it will only work on OS2.0+ Amiga's.
Take a look.If you choose to use #SYS_Asynch,1 the cli will be closed automaticly you could then choose some tag to let the cli open.
BUT ! If you close then the cli before the external task is finished you will have a crash. In this case we have to wait for some code at a own port whe have created. That's why i find using #SYS_Asynch,0 and the external program run a better and easyer way of doing what i wanna do.
Well here is an example of a fully working listview, just in case you get stuck, or even for reference......:
Take a look.Is there a command similar to the word instruction from arexx where I can use X$=Word(A$,1) and if A$="The bees knees" then X$ would = "The" ?
Take a look.If I make a Blitz-executable and run it (by double clicking on it's icon) how do I know which directory it was run from?
Take a look.The problem with ScreenTags is, that it's a statement (Yak! Acid!!), and therefore, if for some reason the screen can't be opened, you don't know and you can't do anything about it. So at the moment my MovieGuide crashes if you try to open a screen using a ModeID that isn't initialized (through the different monitor drivers). But all that will change soon, as I've found this easy solution to the problem, just using the library-function OpenScreenTags_:
Take a look.This example shows the use of the string matching function avaiable with our operative system.
Take a look.This program doesn't extract the files within the .LHA archive, but simply shows infos about the contents...
Take a look.If you've got the ElmoreLibs upgrade on Bum6 installed, you can turn DOS requesters completely off with the SHOWREQUESTERS command. All requesters will act as if the CANCEL gadget had been pressed, so you can construct a routine that way. Here is an example that will wait until a disk is inserted into DF0: without ever bringing up a DOS requester!
Take a look.Hi There. Below is an example of accesing SuperDuper using Arexx via Blitz Basic hope it helps you, If you want more I've a few more examples.
Take a look.This routine is stripped from BlitzBlankPrefs 2.50. It doesn't use Blitz2's ARexx-commands, but the ones from the OS and so works.
It sends the command 'BLANK' to BlitzBlank and then prints the resultstring ("OK").
Take a look.OK, I posted my BlitzBlank-routine to SEND an ARexx-message (did you see that one?), so why not post a routine from BlitzBlank which RECEIVES an ARexx-message:
Take a look.There are some definitions in Amigalibs.Res that would make the flags easier to deal with. You can "OR" them together for combinations as well.
Here they are with a brief example:Yeahh!!! I've done it!!! And it works! And It's fast! And It uses a buffer of 32 bytes!!!! :))
Ok, This program parse the file "ram:aaaa" (modify as you like) and will report if it's a shapes file, or not. I've assumed that the maximum size for a shape is 640 pixels wide, and 512 pixels tall, and obviously 1 to 8 bitplanes.
Shapes by 0x0 pixels and 0 bitplanes can be found, when not used. If any shape into the file doesn't follow these rules the file doesn't contain shapes at all!
Here it is!A small statement for filling windows with a background pattern that I use in MovieGuide Pro V2. First, the statement assumes that you've loaded your pattern as Bitmap number 5. It also assumes that you've examined the screen-structure using BMB's GUI SUPPORT library, using the ExScreen command!
If you don't do that, you'll have to change the following:If those values doesn't give a good result, try other values, but using BMB GUI SUPPORT library is the most flexible way, as it will always be the right values no matter which font/screensize you're using!
Two more variables are needed by the statement, and they are:OK on with it... After you've opened the window you can use the following syntax to fill it out using the Putpattern statement:
Syntax: Putpattern {Window,Close,Border}And here's another small routine for intuition programs that simply makes a BUSY/WAITING window that can be used to bring up messages in your program. It's nothing spectacular, but I use it a lot:-)
Some variables that has to be defined before calling this: